﻿using System.ComponentModel.DataAnnotations;
using System.Runtime.Serialization;

namespace SergeyPravodelov.Practice.BookStore.Models
{
    [DataContract ( Name = "author" )]
    public class BookAuthor
    {
        [Required]
        [StringLength(20)]
        [DataMember(Name = "name")]
        public string Name { get; set; }

        [Required]
        [StringLength(20)]
        [DataMember ( Name = "lastName" )]
        public string LastName { get; set; }
    }
}